package com.ruohi.gift.order;

/**
 * 显示后台订单操作
 * 
 * @author Administrator
 * 
 */
public class ShowBackOrderOperateImpl implements IShowOrderOperate {

	public String assort(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"assort('" + order_num + "');\">配货</a>");
		return sb.toString();
	}

	public String cancel(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"cancel('" + order_num + "');\">取消订单</a>");
		return sb.toString();
	}

	public String finish(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"finish('" + order_num + "');\">完成</a>");
		return sb.toString();
	}

	public String pay(String order_num) {
		return "";
	}

	public String ship(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"ship('" + order_num + "');\">发货</a>");
		return sb.toString();
	}

	public String sendsms(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"sendsms('" + order_num + "');\">短信提醒</a>");
		return sb.toString();
	}
	
	public String refund(String order_num) {
		StringBuffer sb = new StringBuffer();
		sb.append("&nbsp;<a href=\"javascript://void(0);\" onclick=\"refund('" + order_num + "');\">退款</a>");
		return sb.toString();
	}

	public String showTips(String order_num, String mem_no, int order_status) {
		String tips = "";
		switch (order_status) {
		case OrderStatus.WAIT_PAY:
			tips = "下单";
			break;
		case OrderStatus.PAYED:
			tips = "付款";
			break;
		case OrderStatus.ASSORTING:
			tips = "配货";
			break;
		case OrderStatus.SHIPPED:
			tips = "发货";
			break;
		case OrderStatus.FINISHED:
			tips = "完成";
			break;
		case OrderStatus.CANCELED:
			tips = "取消";
			break;
		default:
			break;
		}
		return tips;
	}

	
}